﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="VideosPlayComments.aspx.vb" Inherits="Web_2._0_BMW___X6_Experts_Web_Application.VideosPlayComments" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">

        

        .style2
        {
            color: #3399FF;
        }
    
        .style3
        {
            font-size: x-large;
        }
        .VideoPlayInfo1
        {
            width: 769px;
            text-align: left;
        }
        .VideoPlayInfo2
        {
            height: 72px;
            width: 823px;
            margin-top: 67px;
            margin-bottom: 0px;
        }
        .spacing
        {
            height: 367px;
            width: 911px;
            margin-bottom: 324px;
        }
        .VideosPlayCommentsInfo
        {
            width: 893px;
            height: 56px;
        }
        .VideoPlayFrame
        {
            height: 756px;
            width: 894px;
        }
        .VidStats
        {
            width: 915px;
            height: 245px;
        }
        .AddAndComment
        {
            height: 1088px;
        }
        .AddCommentForVideoInstruction
        {
            height: 78px;
        }
        .addVideoComments
        {
            height: 147px;
            width: 555px;
            margin-top: 106px;
        }
        .statsAndtagsforVideo
        {
            height: 156px;
        }
        .Likes
        {
            width: 228px;
            height: 112px;
            text-align: center;
            font-size: large;
        }
        .VideoTags
        {
            width: 894px;
            height: 132px;
        }
    
        .st
        {
            font-size: medium;
        }
        

        .VideosStats100
        {
            height: 103px;
            width: 873px;
        }
        

        .videoStats200
        {
            height: 102px;
            width: 652px;
        }
        

        .tags
        {
            width: 205px;
            height: 91px;
        }
        

        .likesVideo
        {
            width: 219px;
            height: 89px;
        }
        

        .views
        {
            width: 209px;
            height: 90px;
        }
        

        .style4
        {
            font-size: medium;
            text-decoration: underline;
        }
        .style5
        {
            float: right;
            width: 205px;
            height: 89px;
            text-decoration: underline;
            font-size: medium;
        }
                

        .commentsVideo
        {
            height: 268px;
        }
        

        .commentsVideo2
        {
            height: 31px;
            width: 581px;
        }
        

        .videoObjects
        {
            height: 128px;
        }
        

        </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
<div class = "style3">

        <strong>BMW - X6 </strong><span class="style2"><em><strong>Videos &amp; Media</strong></em></span><strong> Discussion Forum
        </strong>


</div>
<br />

<div class = "AddCommentForVideoInstruction">

    Thank you for logging in and viewing our Videos.
    <br />
    <br />
    To add a comment to this video, simply enter your comment in the box below 
    the video and click on comment!</div>
<br />

<div class = "VideosPlayCommentsInfo">

        <asp:FormView ID="FormView1" runat="server" DataSourceID="SqlDataSource1" 
            Height="41px" Width="870px" BorderStyle="Solid" 
            style="font-size: large; font-family: Calibri; text-align: center;" BorderColor="#3F3F3F" 
            BorderWidth="4px">
            <EditItemTemplate>
                <strong>Title:</strong> <asp:TextBox ID="VideoTitleTextBox" runat="server" 
                    Text='<%# Bind("VideoTitle") %>' />
                <br />
                <strong>Video Link:</strong>
           
                <br />
                <asp:LinkButton ID="UpdateButton" runat="server" CausesValidation="True" 
                    CommandName="Update" Text="Update" />
                &nbsp;<asp:LinkButton ID="UpdateCancelButton" runat="server" 
                    CausesValidation="False" CommandName="Cancel" Text="Cancel" />
            </EditItemTemplate>
            <InsertItemTemplate>
                <strong>Title:</strong> 
                <asp:TextBox ID="VideoTitleTextBox0" runat="server" 
                    Text='<%# Bind("VideoTitle") %>' />
                <br />
                
                <asp:LinkButton ID="InsertButton" runat="server" CausesValidation="True" 
                    CommandName="Insert" Text="Insert" />
                &nbsp;<asp:LinkButton ID="InsertCancelButton" runat="server" 
                    CausesValidation="False" CommandName="Cancel" Text="Cancel" />
            </InsertItemTemplate>
            <ItemTemplate>
                <strong>Title:</strong>
                <asp:Label ID="VideoTitleLabel" runat="server" 
                    Text='<%# Bind("VideoTitle") %>' />
                <br />

                

            </ItemTemplate>
        </asp:FormView>

</div>

<div class = "VideoPlayFrame">

    
        <asp:FormView ID="FormView3" runat="server" DataSourceID="SqlDataSource1" 
            Width="873px" Height="389px" BackColor="#B0CAFF" BorderColor="#3F3F3F" 
            BorderStyle="Solid" BorderWidth="6px" style="margin-bottom: 18px">
            <EditItemTemplate>
                
                    <iframe width="420" height="315" src="http://www.youtube.com/embed/<%# Eval("VideoLink") %>" frameborder="1"></iframe>
                <br />
                <asp:LinkButton ID="UpdateButton" runat="server" CausesValidation="True" 
                    CommandName="Update" Text="Update" />
                &nbsp;<asp:LinkButton ID="UpdateCancelButton" runat="server" 
                    CausesValidation="False" CommandName="Cancel" Text="Cancel" />
            </EditItemTemplate>
            <InsertItemTemplate>
                
                    <iframe width="420" height="315" src="http://www.youtube.com/embed/<%# Eval("VideoLink") %>" frameborder="1"></iframe>
                <br />
                <asp:LinkButton ID="InsertButton" runat="server" CausesValidation="True" 
                    CommandName="Insert" Text="Insert" />
                &nbsp;<asp:LinkButton ID="InsertCancelButton" runat="server" 
                    CausesValidation="False" CommandName="Cancel" Text="Cancel" />
            </InsertItemTemplate>
            <ItemTemplate>
                
                <iframe width="420" height="315" src="http://www.youtube.com/embed/<%# Eval("VideoLink") %>" frameborder="1"></iframe>
                <br />

            </ItemTemplate>
        </asp:FormView>

            <asp:FormView ID="FormView2" runat="server" DataSourceID="SqlDataSource2" 
                Width="874px" BorderStyle="Solid" BorderWidth="4px" BackColor="White" 
                BorderColor="#DEDFDE" CellPadding="4" Font-Bold="False" ForeColor="Black" 
                GridLines="Vertical">
                <EditItemTemplate>
                    <strong>Description:</strong>
                    <asp:TextBox ID="VideoDescriptionTextBox" runat="server" 
                        Text='<%# Bind("VideoDescription") %>' />
                    <br />
                    
                    <strong>Date Uploaded:</strong>
                    <asp:TextBox ID="DateUploadedTextBox" runat="server" 
                        Text='<%# Bind("DateUploaded") %>' />
                    <br />
                    <strong>Time Uploaded:</strong>
                    <asp:TextBox ID="TimeUploadedTextBox" runat="server" 
                        Text='<%# Bind("TimeUploaded") %>' />
                    <br />
                    <strong>Video Posted by:</strong>
                     <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
                    <br />
                    
                    
                    <asp:LinkButton ID="UpdateButton0" runat="server" CausesValidation="True" 
                        CommandName="Update" Text="Update" />
                    &nbsp;<asp:LinkButton ID="UpdateCancelButton" runat="server" 
                        CausesValidation="False" CommandName="Cancel" Text="Cancel" />
                </EditItemTemplate>
                <EditRowStyle BackColor="#CE5D5A" Font-Bold="True" ForeColor="White" />
                <FooterStyle BackColor="#CCCC99" />
                <HeaderStyle BackColor="#6B696B" Font-Bold="True" ForeColor="White" />
                <InsertItemTemplate>
                    <strong>Description:</strong>
                    <asp:TextBox ID="UserNameTextBox1" runat="server" 
                        Text='<%# Bind("UserName") %>' />
                    <br />

                    <strong>Date Uploaded:</strong>
                    <asp:TextBox ID="VideoDescriptionTextBox0" runat="server" 
                        Text='<%# Bind("VideoDescription") %>' />
                    <br />
                    <strong>Time Uploaded:</strong>
                    <asp:TextBox ID="TimeUploadedTextBox1" runat="server" 
                        Text='<%# Bind("TimeUploaded") %>' />
                    <br />
                    <strong>Video Posted by:</strong>
                     <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
                    <br />

                    <asp:LinkButton ID="InsertButton0" runat="server" CausesValidation="True" 
                        CommandName="Insert" Text="Insert" />
                    &nbsp;<asp:LinkButton ID="InsertCancelButton" runat="server" 
                        CausesValidation="False" CommandName="Cancel" Text="Cancel" />
                </InsertItemTemplate>
                <ItemTemplate>
                    <strong>Description:</strong>
                    <asp:Label ID="VideoDescriptionLabel" runat="server" 
                        Text='<%# Bind("VideoDescription") %>' />
                    <br />
                    

                   <strong>Date Uploaded:</strong>
                    <asp:Label ID="DateUploadedLabel" runat="server" 
                        Text='<%# Bind("DateUploaded") %>' />
                    <br />
                   <strong>Time Uploaded:</strong>
                    <asp:Label ID="TimeUploadedLabel" runat="server" 
                        Text='<%# Bind("TimeUploaded") %>' />
                    <br />
                    <strong>Video Posted by:</strong>
                     <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
                    <br />
                    
                    

                </ItemTemplate>
                <PagerStyle BackColor="#F7F7DE" ForeColor="Black" HorizontalAlign="Right" />
                <RowStyle BackColor="#F7F7DE" />
            </asp:FormView>
            <div class = "VideosStats100">
                <div class = "videoStats200">
                    <div class = "stat4" 
                        
                        
                        style="border-style: solid; border-color: #3f3f3f; text-align: center; width: 424px; height: 93px;">
    
    <div class = "style5">
    
        <strong>Views<br />
        <br />
                <asp:Label ID="lblTotalViews" runat="server" Text="Label" Font-Size="Medium" 
                    BorderStyle="Inset" Width="74px"></asp:Label>
            </strong>
    
    </div>
    <div class = "views">
    
        <strong><span class="style4">Likes</span></strong><br />

                <asp:Image ID="imgLike" runat="server" Height="35px" 
                    ImageUrl="~/Pictures/imgLiked.jpg" style="text-align: center" 
                    Width="55px" />
                <asp:Label ID="lblTotalCounts" runat="server" Text="Label" Font-Size="Medium" 
                    BorderStyle="Inset" Width="57px"></asp:Label>
            
            
            
                <asp:Button ID="btnLike" runat="server" Height="28px" 
                    style="text-align: left" Text="Like This Image" Width="133px" 
                    Font-Bold="True" Font-Italic="True" />
            
            
                
    </div>
    
    
    
    
    </div>
    
    
  
            
            </div>
            </div>

            <div class = "videoObjects">
            
            <strong>Comment on the Video:</strong><br />
        
            <asp:TextBox ID="txtAddVideoComment" runat="server" Height="96px" Width="391px" 
                TextMode="MultiLine"></asp:TextBox>
            <asp:Button ID="btnAddComment" runat="server" Height="41px" Text="Add Comment" 
                Width="151px" BackColor="#99CCFF" />
          
            </div>
</div>
<div class = "commentsVideobox">



</div>


    <asp:ListView ID="ListView1" runat="server" DataSourceID="SqlDataSource3">
        <AlternatingItemTemplate>
            
            <strong>Comment:</strong>
            <asp:Label ID="CommentBodyLabel" runat="server" 
                Text='<%# Eval("CommentBody") %>' />
            <br />
            <strong>Date Uploaded:</strong>
            <asp:Label ID="DateUploadedLabel" runat="server" 
                Text='<%# Eval("DateUploaded") %>' />
            <br />
            <strong>Time Uploaded:</strong>
            <asp:Label ID="TimeUploadedLabel" runat="server" 
                Text='<%# Eval("TimeUploaded") %>' />
            <br />
            <strong>Comment Posted by:</strong>
            <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
            <br />
            
<br /></span>
        </AlternatingItemTemplate>
        <EditItemTemplate>
            <span style="">VideoCommentID:
            <asp:Label ID="VideoCommentIDLabel1" runat="server" 
                Text='<%# Eval("VideoCommentID") %>' />
            <br />
            CommentBody:
            <asp:TextBox ID="CommentBodyTextBox" runat="server" 
                Text='<%# Bind("CommentBody") %>' />
            <br />
            DateUploaded:
            <asp:TextBox ID="DateUploadedTextBox" runat="server" 
                Text='<%# Bind("DateUploaded") %>' />
            <br />
            TimeUploaded:
            <asp:TextBox ID="TimeUploadedTextBox" runat="server" 
                Text='<%# Bind("TimeUploaded") %>' />
            <br />
            UserName:
             <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
            <br />
            VideoID:
            <asp:TextBox ID="VideoIDTextBox" runat="server" Text='<%# Bind("VideoID") %>' />
            <br />
            <asp:Button ID="UpdateButton" runat="server" CommandName="Update" 
                Text="Update" />
            <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" 
                Text="Cancel" />
            <br /><br /></span>
        </EditItemTemplate>
        <EmptyDataTemplate>
            <span>No data was returned.</span>
        </EmptyDataTemplate>
        <InsertItemTemplate>
            <span style="">CommentBody:
            <asp:TextBox ID="CommentBodyTextBox" runat="server" 
                Text='<%# Bind("CommentBody") %>' />
            <br />DateUploaded:
            <asp:TextBox ID="DateUploadedTextBox" runat="server" 
                Text='<%# Bind("DateUploaded") %>' />
            <br />TimeUploaded:
            <asp:TextBox ID="TimeUploadedTextBox" runat="server" 
                Text='<%# Bind("TimeUploaded") %>' />
            <br />UserName:
             <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
            <br />VideoID:
            <asp:TextBox ID="VideoIDTextBox" runat="server" Text='<%# Bind("VideoID") %>' />
            <br />
            <asp:Button ID="InsertButton" runat="server" CommandName="Insert" 
                Text="Insert" />
            <asp:Button ID="CancelButton" runat="server" CommandName="Cancel" 
                Text="Clear" />
            <br /><br /></span>
        </InsertItemTemplate>
        <ItemTemplate>
            
            
            <strong>Comment:</strong>
            <asp:Label ID="CommentBodyLabel" runat="server" 
                Text='<%# Eval("CommentBody") %>' />
            <br />
            <strong>Date Uploaded:</strong>
            <asp:Label ID="DateUploadedLabel" runat="server" 
                Text='<%# Eval("DateUploaded") %>' />
            <br />
            <strong>Time Uploaded:</strong>
            <asp:Label ID="TimeUploadedLabel" runat="server" 
                Text='<%# Eval("TimeUploaded") %>' />
            <br />
            <strong>Comment Posted by:</strong>
             <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
            <br />
            
<br /></span>
        </ItemTemplate>
        <LayoutTemplate>
            <div ID="itemPlaceholderContainer" runat="server" style="">
                <span runat="server" id="itemPlaceholder" />
            </div>
            <div style="">
             <asp:DataPager ID="DataPager1" runat="server" PagedControlID="ListView1" PageSize="10">
                            
                                <Fields>
                                    <asp:NextPreviousPagerField ButtonType="Button" ShowFirstPageButton="True" 
                                        ShowNextPageButton="False" ShowPreviousPageButton="False" />
                                    <asp:NumericPagerField />
                                    <asp:NextPreviousPagerField ButtonType="Button" ShowLastPageButton="True" 
                                        ShowNextPageButton="False" ShowPreviousPageButton="False" />
                                </Fields>
                            </asp:DataPager>
            </div>
        </LayoutTemplate>
        <SelectedItemTemplate>
            <span style="">VideoCommentID:
            <asp:Label ID="VideoCommentIDLabel" runat="server" 
                Text='<%# Eval("VideoCommentID") %>' />
            <br />
            CommentBody:
            <asp:Label ID="CommentBodyLabel" runat="server" 
                Text='<%# Eval("CommentBody") %>' />
            <br />
            DateUploaded:
            <asp:Label ID="DateUploadedLabel" runat="server" 
                Text='<%# Eval("DateUploaded") %>' />
            <br />
            TimeUploaded:
            <asp:Label ID="TimeUploadedLabel" runat="server" 
                Text='<%# Eval("TimeUploaded") %>' />
            <br />
            UserName:
             <a href="UserProfileView.aspx?Username=<%# Eval("UserName") %>"><asp:Label ID="UserNameLabel" runat="server" Text='<%# Eval("UserName") %>' /></a>
            <br />
            VideoID:
            <asp:Label ID="VideoIDLabel" runat="server" Text='<%# Eval("VideoID") %>' />
            <br />
<br /></span>
        </SelectedItemTemplate>
    </asp:ListView>
    <asp:SqlDataSource ID="SqlDataSource3" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" 
        SelectCommand="SELECT Video_Comments.CommentBody, Video_Comments.DateUploaded, Video_Comments.TimeUploaded, aspnet_Users.UserName, Video_Comments.VideoID, Video_Comments.VideoCommentID FROM (aspnet_Users INNER JOIN Video_Comments ON aspnet_Users.UserId = Video_Comments.UserID) WHERE (Video_Comments.VideoID = ?) ORDER BY Video_Comments.VideoCommentID DESC">
        <SelectParameters>
            <asp:QueryStringParameter Name="?" QueryStringField="id" />
        </SelectParameters>
    </asp:SqlDataSource>
    <asp:SqlDataSource ID="SqlDataSource2" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" 
        
        SelectCommand="SELECT Videos.VideoDescription, Videos.DateUploaded, Videos.TimeUploaded, aspnet_Users.UserName, Videos.VideoID FROM (aspnet_Users INNER JOIN Videos ON aspnet_Users.UserId = Videos.UsernameID) WHERE (Videos.VideoID = ?)">
        <SelectParameters>
            <asp:QueryStringParameter Name="?" QueryStringField="id" />
        </SelectParameters>
    </asp:SqlDataSource>

        <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" 
        SelectCommand="SELECT VideoTitle, VideoLink FROM Videos WHERE (VideoID = ?)">
            <SelectParameters>
                <asp:QueryStringParameter Name="?" QueryStringField="id" />
            </SelectParameters>
    </asp:SqlDataSource>




</asp:Content>
